package com.game.jinhua;

import com.game.net.server.jpbsocket.JPbSocketNettyServer;
import com.game.common.QueueEventThread;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * Created by legend9999 on 2016/6/5.
 */
public class JinhuaMain {
	private static Logger logger = LoggerFactory.getLogger(JinhuaMain.class);

	public static void main(String[] args) {
		ApplicationContext ac = new ClassPathXmlApplicationContext("spring.xml");
		new Thread(ac.getBean(QueueEventThread.class)).start();
		JinHuaJPbServerHandler jinHuaJPbServerHandler = ac.getBean(JinHuaJPbServerHandler.class);
		JPbSocketNettyServer jPbSocketNettyServer = ac.getBean(JPbSocketNettyServer.class);
		jPbSocketNettyServer.init(50000,jinHuaJPbServerHandler);
	}
}
